#include <iostream>
#include <memory>
#include "udpClient.hpp"

void Usage(const char* proc)
{
    std::cout << "\nUsage:\n\t" << proc << " server_ip server_port\n" << std::endl;
}

int main(int argc, char* argv[])
{
    if(argc != 3)
    {
        Usage(argv[0]);
        exit(Usage_ERR);
    }

    std::string serverip = argv[1];
    uint16_t serverport = atoi(argv[2]);
    std::unique_ptr<udpClient> uclt(new udpClient(serverip, serverport));
    uclt->initClient();
    uclt->run();

    return 0;
}